home *** CD-ROM | disk | FTP | other *** search
/ LSD Docs / LSD Docs.iso / FILEZ / lsd15.dms / lsd15.adf / PowerWindows2.5.doc.pp / PowerWindows2.5.doc
Text File  |  1991-02-19  |  54KB  |  1,038 lines

  1.                                 POWER WINDOWS 2.5
  2.  
  3. Typed by RIVER BOY.
  4.  
  5.  
  6. PowerWindows 2.5 is the interactive, interface programming aid for the Amiga
  7. computer. It provides you, the programmer, the ability to quickly create and
  8. edit screens, windows, menus, and gadgets for your programs, with none of
  9. the fuss or tedium of coding the necessary structures yourself. All you have
  10. to do is move a mouse and push a button to:
  11.  
  12.      create new screens and windows;
  13.      edit old screens and windows;
  14.      "grab" (import) windows running elsewhere in the system;
  15.      add, move, delete, or edit window text;
  16.      modify window characteristics;
  17.      include or exclude IDCMP or other window flags;
  18.      add, move, edit or delete a menu;
  19.      add, move, edit or delete items and subitems in a menu;
  20.      add gadgets, move gadgets, clone gadgets, re-size gadgets,
  21.           set gadget characteristics, enter gadget text, and
  22.           delete gadgets;
  23.      add and manipulate Knob, PopUpMenu, and DragGadget
  24.           constructs as used with InovaTools1;
  25.      include IFF brush imagery in your gadgets or menus;
  26.      generate source code for all of the above;
  27.      and save your creations on disk for future editing.
  28.  
  29. PowerWindows  provides  you  with  instant  feedback,  allowing  you to see
  30. exactly  how  your  creation  will  look without the trial-and-error of the
  31. edit/compile/examine  loop.   You  can effectively see your windows outside
  32. your program, complete with menus, menuitems, subitems, text and gadgets --
  33. almost  as  if  you  were  already  running  your  program.   When  you are
  34. satisfied, select your language and PowerWindows creates the structures for
  35. you.   Save  your design in the intermediate file format so that it will be
  36. available should you ever need to modify or add to it, or generate the same
  37. data for a different language.
  38.  
  39. NOTE:   You  will  need  to provide the necessary entry points or procedure
  40. names to properly interface the generated code with your program.
  41.  
  42. REQUIREMENTS:   Amiga  with  512K  RAM  and  at  least one disk drive, with
  43. KickStart/Intuition  version  1.2.  Also required are the necessary include
  44. files for the language of your choice which define the Intuition structures
  45. that PowerWindows generates.
  46.  
  47.  
  48. GETTING STARTED:
  49.  
  50. PowerWindows  requires  no installation.  We recommend that you make a copy
  51. of  PowerWindows  and  put  the original in a safe place, away from hazards
  52. like  fire,  strong  magnetic  fields,  and  pirates.   Use  the  copy as a
  53. "master", and use the original only for making new legal copies.
  54.  
  55. Unlike  the  program,  you  might require some installation yourself.  This
  56. software expects you to be familiar with the Amiga and with the programming
  57. language  of  your choice.  This means that we won't be defining terms like
  58. drag  bar (no jokes, please) or gadget.  PowerWindows is a serious tool for
  59. serious programmers.
  60.  
  61. PowerWindows can be run from either the Workbench or the CLI environments.
  62.  
  63. PowerWindows  starts  with  a  blank,  640  x  200 window, on the Workbench
  64. screen.   This  is  the  "command window".  To see just how simple it is to
  65. create  a PowerWindows interface design, get PowerWindows running and press
  66. the Right-Amiga N key.  This will open a new window on the Workbench screen
  67. called  "Your  new  window".   At this stage you could immediately generate
  68. source  for  "C" or assembler which would create the data needed to exactly
  69. duplicate that window.  But first, let's dress it up a bit..
  70.  
  71. Start  by resizing the window and positioning it any way you like.  It is a
  72. real Intuition window so the drag bar, depth-arrangement and sizing gadgets
  73. all work.
  74.  
  75. Next,  press  Right-Amiga A and read the message in the requester that pops
  76. up  at  the  top of the screen.  This message explains how to use the Add a
  77. gadget  command  that we have just invoked.  When you have finished reading
  78. the  text,  press  the  OK  gadget on the requester and position your mouse
  79. somewhere  over  the center of "Your new window" and click the left button.
  80. This  tells  PW2.5 where you want the TopLeft pixel of your gadget's border
  81. to  be  drawn.   Now drag the mouse inside the window and PW2.5 will follow
  82. your movements and size the area of the gadget accordingly.  After you have
  83. dragged the mouse around for a bit, press the HELP key on your keyboard and
  84. PW2.5  will  redisplay  the original message describing what you are doing.
  85. If  you forget which action you are expected to take or just want to CANCEL
  86. an  action once it has already begun, you can always press the HELP key for
  87. a  reminder  and  a chance to change your mind.  For now, just press the OK
  88. gadget  and  put  your  mouse  back into "Your new window".  PowerWindows ,
  89. waiting  for you to make a final decision about the size of the new gadget.
  90. Click inside the window to tell PW when you are done.
  91.  
  92. Now  you  have a real window with a real BOOLEAN gadget in it, but we still
  93. need  a  menu.  So press Right-Amiga M and PW will open a requester used to
  94. specify several options about menus, but right now we just want to key in a
  95. name  for  our  first  menu,  so  just  type  in  "My  First Menu" into the
  96. preactivated string gadget labeled MENU TEXT.  Next press the OK gadget and
  97. the  requester  will close.  Your window now has a real menu attached to it
  98. with one menuitem called "dummy".  If you need proof, click on the drag bar
  99. of  "Your  new  window",  followed by the right mouse button.  Your menu is
  100. there  and  it  looks  exactly the way it would look in your program if you
  101. generated  source  code  for this window right now.  So let's do that right
  102. now.
  103.  
  104. Press  Right-Amiga  G and a requester will open with the names of the three
  105. language  generators  that PW2.5 has built-in listed in gadgets at the top.
  106. Press  on  the  language you want and then press on the word OUTPUT (not in
  107. the  string  gadget  to  the  right  of  the word) and the InovaTools1 file
  108. requester  will  open allowing you to specify the complete filename for the
  109. output  file you want to generate.  Choose a filename like "ram:test.c", or
  110. at least some filename that you wont mind letting PW use.
  111.  
  112. Once  you  have  specified  a  filename for our little test window's source
  113. code,  the file requester will close and stuff the filename into the OUTPUT
  114. string  gadget.  If you already know the filename, of course you can key it
  115. directly  in  this  box.   Finally,  press the OK gadget on the source code
  116. generation requester and PW2.5 will write a file with all the data you need
  117. to duplicate this simple interface in your own software.
  118.  
  119. Now,  we  want  to  save this design for later editing, of course, so press
  120. Right-Amiga  S  and  the file requester will reappear to let you indicate a
  121. save  filename.  By default PW will save your file with the ".pw" extension
  122. added  to  the  name, but you can use any extension you want by typing into
  123. the  box  on the file requester labeled Type and pressing RETURN, or use no
  124. extension  at  all  by  deleting  all characters in this field and pressing
  125. RETURN.   Once you have specified the filename press the Save gadget on the
  126. file  requester  and  the  save will be made.  In the case of a disk error,
  127. PowerWindows will report it to you and allow you to try the save again.
  128.  
  129. Now  that  the file is saved, you can Quit PW2.5 and come back to that same
  130. file  anytime  using  the Right-Amiga L option, and then just pick right up
  131. where you left it last time.
  132.  
  133. That  was  a  simple  PowerWindows  2.5  editing session.  Now use the menu
  134. button to see the main menustrip, which consists of seven primary menus:
  135.  
  136.      Project
  137.      Screens
  138.      Windows
  139.      Menus
  140.      Gadgets
  141.      Knobs
  142.      Preferences
  143.  
  144. Each  of  the  menus  listed above are discussed in the sections following.
  145. This manual is organized in the same way that the menus are organized.
  146.  
  147.  
  148. PROJECT:
  149.  
  150. Under the Project menu you will find the following:
  151.  
  152.      Generate source code
  153.      Save configuration
  154.      Save screen and/or windows
  155.      Load screen and/or windows
  156.  
  157.      Kill everything
  158.  
  159.      Quit...
  160.  
  161. Generate source code is the whole point of PowerWindows.  This command lets
  162. you  specify  the  language of your choice and several other options.  (For
  163. languages  other  than  "C"  and 68000 assembler, you must use the specific
  164. language translator program provided for that language, which you will find
  165. on  your distribution disk.  These translator programs use the intermediate
  166. file  format  generated  by the Save screen and/or windows command.) Before
  167. starting the code generation, you must specify the OUTPUT filename.  If you
  168. don't know the filename to use, you can click on the word OUTPUT for a file
  169. requester.   You  may also specify a HEADER filename.  The HEADER file is a
  170. file  that  you  wish  copied into the start of the source generated by PW.
  171. This  file  may  contain definitions, include statements, or anything else.
  172. You may click on the word HEADER for a file requester if you need one.
  173.  
  174. You  can also control which "sections" of the source code to generate.  For
  175. example,  assume you have created a source file with PowerWindows, and then
  176. edited  it  for some particular purpose; if you need to edit that design in
  177. the  future  and  regenerate the source code, PW will allow you to generate
  178. source for only those parts of the design that have changed.  Just turn off
  179. the  sections  that  you  do  not  want  generated.   The sections include:
  180. SCREEN,  PALETTE,  WINDOWS, GADGETS, MENUS, WINDOWTEXT, RENDER (BORDER ONLY
  181. and IMAGE ONLY gadgets), and EVENTS (the event handler).
  182.  
  183. The  LOCAL  STRUCTURES option instructs PW to make all structures generated
  184. local,  if  the  target  language  supports  such a concept.  An example is
  185. static structures in C.  Finally, the BORDERS/IMAGES GADGET option tells PW
  186. to generate a special gadget as a link for the render of any BORDER ONLY or
  187. IMAGE  ONLY  gadgets (see Define gadget type for details) that may exist in
  188. your design.  In other words, rather than create the standalone linked list
  189. of  Borders/Images that would normally be created, PW will link those lists
  190. into  a  gadget  designed just for rendering that data.  The gadgets have a
  191. size  of  zero,  use  no highlighting and are placed in the extreme TopLeft
  192. corner of the window that they inhabit.
  193.  
  194. Save  configuration  lets  you  save your current Preferences settings to a
  195. file  called  "devs:pw2-configuration".   This file is automatically loaded
  196. when  PW is invoked.  Note that your preferences are also saved to every PW
  197. intermediate file that you make, and are loaded from those files.
  198.  
  199. Save  screen  and/or  windows  will  save  information to a file about your
  200. screen  and  windows in a format that PowerWindows can read to recreate it.
  201. If you wish to retain the ability to edit your current design, you must use
  202. this  option.  We suggest that you append ".PW" to the filename to indicate
  203. what  kind of file your are saving.  (The file requester also automatically
  204. looks  for  .PW  files  as  a  default.) At any time in the future, you can
  205. select  Load screen and/or windows from the Project menu and read this file
  206. to  examine  and edit this design.  Your PW Preferences settings and source
  207. code generation options are also stored in this file.  Note that additional
  208. PW  support programs, such as generators for other languages, use this type
  209. of  file.   In  the  future, INOVATRONICS will provide tools allowing other
  210. uses for this format.
  211.  
  212. Load  screen  and/or windows loads a file generated in the above manner and
  213. opens  the  windows  and screen contained therein.  Note that PW will merge
  214. the  incoming  windows with any current windows you are working with.  If a
  215. custom  screen  is found in the file, and you already have a custom screen,
  216. PW  will  prompt  you to ask if you wish to replace the current screen with
  217. the  one  from  the file.  The Preferences in use are always those from the
  218. most recently loaded intermediate file.
  219.  
  220. Once  you  have  loaded  a  file in this way, you can manipulate all of the
  221. objects  in  your  design,  exactly  as if you had just created them.  This
  222. allows  you to easily play with interface designs, move this object here or
  223. there, and experiment.
  224.  
  225. One  extremely  practical  way  to  make use of this feature is to create a
  226. "toolbox"  window of gadgets or knobs that you use on a regular basis, then
  227. save that window as a normal PW intermediate file.  Then, whenever you need
  228. a  gadget  just  like  one of the ones in your toolbox, you can re-load the
  229. window  and move or clone a gadget out of that window, and into the one you
  230. are  currently  designing.  After you have what you need from your toolbox,
  231. you can simply remove it with the Kill window command.
  232.  
  233. Kill everything will close any custom screen and all windows with which you
  234. are currently working.  There is no undo feature.  Be warned.
  235.  
  236. Quit...   means  just  that.   Make  sure  you've saved an editable file if
  237. there's  any  chance  you might need to change the display on which you are
  238. working.   (Re-creating a complex window with many menus and gadgets is far
  239. easier   with  PowerWindows  than  without  it,  but  it  IS  still  work.)
  240. PowerWindows will ask you if you wish to abandon any changes you have made,
  241. if you have not saved at least an editable file to disk.
  242.  
  243.  
  244. SCREENS:
  245.  
  246. You can design custom screens and palettes with the Screens functions.
  247.  
  248. Define  screen  type  will  present  you  with  a window with which you can
  249. determine  your  screen's  dimensions, the number of bitplanes it uses, the
  250. pen  numbers,  default font and title for the screen.  Use these gadgets to
  251. control  the  type  of  screen you get, select the CUSTOMSCREEN gadget, and
  252. press  OK.   A  new  screen will appear with the indicated characteristics.
  253. All  windows  that  you  later  open will appear on this screen, or, if you
  254. already have windows open, they will be moved to this screen.  Four gadgets
  255. are  provided for selecting any one of the four standard NTSC screen sizes,
  256. however  you  may  key  any  dimensions  you like into the Width and Height
  257. gadgets  at  the top of the requester.  PW will not verify that the numbers
  258. you  have  chosen  are  legal; this is your responsibility.  To return to a
  259. Workbench screen, select the WBENCHSCREEN gadget and press OK.
  260.  
  261. Several flags appear under the Screen Flags section of this requester which
  262. are  not  WYSIWYG,  but  will  be  generated in your source code.  The same
  263. applies to the CUSTOMBITMAP POINTER string and the GADGETLIST string.
  264.  
  265. To  move  quickly  between the PW command window, which is on the Workbench
  266. screen, and your custom screen, you can use the F1 and F2 keys.
  267.  
  268. Screen  Palette  brings up a palette editor which you can use to change the
  269. RGB  settings  for  your  screen's colors.  The colors on the requester are
  270. oriented  left-to-right  beginning  with  color  0.   You  can use the READ
  271. PALETTE FROM IFF gadget to specify an IFF brush filename from which to read
  272. a  palette.   If  you  need  a file requester to help you select the proper
  273. file,  click  over  the  phrase  READ PALETTE FROM IFF.  If you modify your
  274. palette,  only  to later change your screen definition, the palette changes
  275. may  be  lost.   A  color  palette  is maintained through screen definition
  276. changes  only if the number of bitplanes used in the old and the new custom
  277. screens is the same.
  278.  
  279.  
  280. WINDOWS:
  281.  
  282. PowerWindows  2.5  lets you work with any number of windows simultaneously.
  283. However,  all the commands relating to windowtext and menus operate only on
  284. the context window.  For example, if you have two windows open and you tell
  285. PW  to Redisplay, it will redisplay the current context window.  You switch
  286. context  windows  by  clicking  inside  the  window that you want to become
  287. active.   You  can switch context windows only when PW is waiting for input
  288. at the main menu level.
  289.  
  290. Under the Windows menu heading you'll see:
  291.  
  292.      Open new window
  293.      Grab a window
  294.      Redisplay
  295.      Clean up
  296.      Edit window characteristics
  297.      Kill window
  298.      Write window text
  299.      Move window text
  300.      Edit window text
  301.  
  302.      Delete window text
  303.  
  304. Open  new window opens a new Intuition window on the Workbench screen or on
  305. your  custom  screen  if  you  have  made one.  You can do anything to this
  306. window  that you like because it is an actual window.  At various times, PW
  307. will  read  information from this window's structure regarding its position
  308. and  size,  but  you can play with it freely.  The new window automatically
  309. becomes  the  context window for windowtext and menus.  To quickly reselect
  310. the  PW  command  window,  you  can  press  F1, click inside the PW command
  311. window,  or  if  Auto  select is on, just click inside any one of your edit
  312. windows.
  313.  
  314. Grab  a  window  is one of the most powerful PW commands.  It allows you to
  315. import  any window running at the time as a PowerWindows construct and edit
  316. it  as  if you had generated it manually.  After selecting this option, you
  317. will have a new menustrip with the following menus:
  318.  
  319.      Screens
  320.      Other
  321.  
  322. On  the  Screens  menu  you  will  find  a list of all screens open at that
  323. moment,  and  a  list  of  all windows open on each screen will be shown as
  324. subitems  to  that screen.  The windows and screens are identified by their
  325. titles.   If  a  screen  or  window has no title, its item will appear as a
  326. blank.   To  grab  one  of  the  windows listed, just select its name.  The
  327. window,  with  all  of  its  menus and gadgets will be imported into PW for
  328. instant  editing.   Note that some things are not grabbed, such as imagery,
  329. borders,  or  text that were drawn into the window individually and are not
  330. connected  to  any  gadget  or  menu.   For each gadget grabbed that uses a
  331. border  for  render, a custom border is created.  You may delete or replace
  332. this border by doing border work on that gadget.  All menus are set to USER
  333. FORMATTING  when grabbed because PW wants to maintain the original look and
  334. positioning  of  the  grabbed  menus.   If you are grabbing a window from a
  335. screen   of  a  resolution  different  from  the  one  you  are  designing,
  336. PowerWindows may have to change the size or origin of the window to make it
  337. fit.  The Other menu allows you to return to the main menu.
  338.  
  339. Redisplay  refreshes  your current window, cleaning up any display problems
  340. that might result from your editing.  The raster of your window is blanked,
  341. then all gadgets, knobs and windowtext are redrawn into it.
  342.  
  343. Clean  up  is  provided to ensure that all gadgets and knobs in your window
  344. are  actually  in the displayable area of your window.  For example, if you
  345. have put a knob or gadget in the far right-hand side of your window and you
  346. then  make the window more narrow by resizing it to the left, those gadgets
  347. and/or  knobs  may  be  no  longer  in your view.  This can cause problems,
  348. because in order to manipulate a gadget or knob with PowerWindows, you must
  349. be  able  to  select it with the mouse.  The Clean up command will move any
  350. gadgets  or  knobs  which are outside the display area back into it.  Also,
  351. because  of  gadget  WYSIWYG relativity, it is possible for you to create a
  352. gadget  with  a  hitbox which has a negative size.  PW will detect any such
  353. problems and correct them when this command is used.
  354.  
  355. Edit  window  characteristics  gives  you  the  opportunity  to specify the
  356. following:
  357.  
  358.      Detail and block rendering pens;
  359.      Minimum and maximum window dimensions:
  360.      Current window dimensions;
  361.      Current window position;
  362.      Window title;
  363.      Window type (window or requester)
  364.      Window ID prefix (added to all structure names for this window
  365.      IDCMP flags and window flags
  366.  
  367. The  IDCMP flags in this window can be toggled ON or OFF to include them or
  368. not  in  the generated source code, but during editing the window has IDCMP
  369. flags used by PowerWindows internally.  (To see what they are, try grabbing
  370. one!)  Of  the  normal  window  flags,  these  are  WYSIWYG:   WINDOWCLOSE,
  371. WINDOWDRAG, WINDOWDEPTH, WINDOWSIZE, SIZEBBOTTOM, SIZEBRIGHT, BACKDROP, and
  372. BORDERLESS.   See the Amiga ROM Kernal manuals for complete descriptions of
  373. the flags listed on this display.
  374.  
  375. If  you  want  PW  to  make  a  Requester structure rather than a NewWindow
  376. structure  at  source  code generation time, you can hit the gadget labeled
  377. TYPE, and it will toggle between WINDOW and REQUESTER.
  378.  
  379. Kill  window  will remove the current window.  Be sure to select the window
  380. you want to destroy before using this option, as there is no UNDO command.
  381.  
  382. Write  window  text lets you write a string of text to be displayed in your
  383. window.   After  keying  in the text, click OK and move your pointer to the
  384. location  in  your  window  where you want the upper left-hand pixel of the
  385. first  character  of the text to appear.  Click here (the text appears) and
  386. drag  the pointer to position the text more exactly.  Click again when your
  387. text  is  properly  positioned.   (Windowtext and gadgettext are different.
  388. Windowtext is relative to a window and in the source code is generated as a
  389. linked  list  of  IntuiText  structures  that  you can draw into the window
  390. yourself  with  a  single  PrintIText  call.   Gadgettext  is relative to a
  391. gadget.  If you move the gadget, the text will move with it.  If you delete
  392. a gadget -- BAM!  -- the text is gone too.  Gadgettext is also generated in
  393. source as a linked list of IntuiText structures, but they are referenced by
  394. the  gadget they were designed with and will be automatically rendered when
  395. their parent gadgets are rendered.)
  396.  
  397. Edit  window  text  displays  as subitems one or more text strings that you
  398. have  previously entered for this window.  (If none have been entered, this
  399. and subsequent menuitems are disabled.) Just select the text string subitem
  400. that  you  would  like to edit.  This gives you a window from which you can
  401. choose  text pens, drawmode and font (default, TOPAZ-SIXTY or TOPAZ-EIGHTY)
  402. as  well  as  edit  the text and its offsets from the TOPLeft corner of the
  403. window.  All source code needed to duplicate your text will be generated by
  404. PowerWindows,  including TextAttr structures for the fonts.  After editing,
  405. the window will be redisplayed with any text changes shown.
  406.  
  407. Move window text gives you the ability to move individual strings of window
  408. text around in the window.  The movement of the text within the window will
  409. be  relative  to  the  position of your pointer when you first click inside
  410. your window.  This gives you the ability to click somewhere near your text,
  411. but not on it, so that you can see the entire text string as you move it.
  412.  
  413. Delete  window  text  enables you to remove unwanted text from your window.
  414. Just select the text to kill and POOF!  It's gone.
  415.  
  416.  
  417. MENUS:
  418.  
  419. Making menus with PowerWindows 2.5 is very easy.  The menus that you create
  420. are,  at  all  times, real menus, attached to the window with which you are
  421. working.   Therefore,  you  can  see what your menu looks like at any time.
  422. Plus,  if you are working with a custom screen, you can see the menu in the
  423. resolution  in  which  it  will be used.  To see the menus for a particular
  424. window,  you must select that window.  If the Auto select preference is ON,
  425. you  can  only  select the window by clicking on one of its system gadgets,
  426. like a drag bar or foreground gadget.  If the window has no system gadgets,
  427. you  can  add them with the Edit window characteristics command, or you can
  428. turn off Auto select and just click inside the window.
  429.  
  430. Under  normal conditions, all menu elements are automatically positioned by
  431. Power Windows.  This is called AUTO FORMATTING.  PW will always do its best
  432. to  see  that  the  menuitems  and  subitems are visible when the menus are
  433. rendered,  and  are  attractively  arranged.  However, you can position the
  434. items  yourself,  if  you like, by setting the USER FORMATTING flag for the
  435. menu  or  item  and specifying the needed pixel values.  But be careful; if
  436. you use irrational values, your computer will respond irrationally!  If you
  437. do  not  set the USER FORMATTING flag, PW will ignore any pixel values that
  438. you set.
  439.  
  440. The  Menus  menu  deals  with  menus, menuitems, and menu subitems for your
  441. current  window.   Your menus are dynamically updated every time you make a
  442. change  to them.  You can append a menu to the end of the menu tree, or you
  443. can  insert  a  new  menu in front of others.  You can rearrange the menus,
  444. delete  them,  etc.  You can also do the same things with the menuitems for
  445. each  menu  and  with  the  subitems  for  each  menuitem.   You can attach
  446. Amiga-keys  to menuitems and subitems, and have the items checked/unchecked
  447. or  enabled/disabled  by Intuition.  You can instruct Intuition to un-check
  448. certain  menuitems or subitems when others are selected.  You can also load
  449. imagery for the rendering of menuitems and subitems.
  450.  
  451. The Menus menu shows you:
  452.  
  453.      Append a menu
  454.      Insert a menu before...
  455.      Move a menu
  456.      Edit a menu
  457.      Work on menuitems for...
  458.  
  459.      Delete a menu
  460.  
  461. Append a menu lets you to enter the name of a new menu, choose AUTO or USER
  462. FORMATTING, and set/reset the MENUENABLED flag.  After you OK the settings,
  463. PowerWindows  creates a menu with that name and attaches a "dummy" menuitem
  464. to  it.   (This  dummy goes away when you add a real menuitem to the menu.)
  465. All menus created in this manner are appended to your menustrip (i.e., list
  466. of menus).
  467.  
  468. Insert  a  menu before...  shows you the menus that exist.  When you select
  469. one  of  them,  you will be prompted for the name of the new menu to insert
  470. before the selected one.
  471.  
  472. Please  note  that  only  the first 15 characters of each menu name will be
  473. displayed  here;  the full menu name will be used in your window and in any
  474. generated  source code.  This truncation applies to menuitem names, subitem
  475. names, gadgettext and windowtext, as well.
  476.  
  477. Move  a  menu lets you move a menu toward the back of the list (the end) or
  478. toward  the  front  of  the list (the start).  You can move a menu only one
  479. position  at a time, so you may have to invoke Move a menu several times to
  480. get things just so.
  481.  
  482. Edit a menu lets you change all the settings of a selected menu.
  483.  
  484. Work  on  menuitems  for...   allows you to attach menuitems, subitems, and
  485. their options to the menu you select.  See the next section for details.
  486.  
  487. Delete  a  menu removes the selected menu from the menu tree.  Use this one
  488. with  caution,  as  it  removes  everything  having  to  do with that menu,
  489. menuitems, subitems and all.
  490.  
  491.  
  492. MENUITEMS:
  493.  
  494. When  you  select  a  menu  form  Work on menuitems for..., you are given a
  495. completely new menustrip from which to work.  It has two menus:
  496.  
  497.      MenuItems
  498.      Other
  499.  
  500. Menuitems looks, and is, similar to the Menus menu, but "menuitem" replaces
  501. "menu"  and  "subitem" replaces "menuitem", and there is one more choice on
  502. the  menu;  Work  on  images  for..."  Basically,  however,  you  can do to
  503. menuitems what you did to menus:
  504.  
  505.      Append a menuitem
  506.      Insert a menuitem before...
  507.      Move a menuitem
  508.      Edit a menuitem
  509.      Work on images for...
  510.      Work on subitems for...
  511.  
  512.      Delete a menuitem
  513.  
  514. Under  AUTO  FORMATTING  the  width of the longest hit box in your menuitem
  515. list  determines  the  width  of all the menuitem hit boxes in the menuitem
  516. list  for  that  menu.  You can pad your menuitem names with spaces to make
  517. the box wider, or play with the choices you get in the editing window.
  518.  
  519. Append a menuitem, Insert a menuitem before..., and Edit a menuitem all use
  520. a  window  that allows you to specify a number of Intuition menuitem flags,
  521. text  for  the item, as well as an alternate command key for the item.  You
  522. can  also control the presentation of the IntuiText rendered in your window
  523. with  this  option.   The  ROOM  FOR CHECK and ROOM FOR ALTKEY provide some
  524. additional spacing to the left and right of the item render for a checkmark
  525. and  an  alternate command key, respectively.  The FUNCTION gadget lets you
  526. key  in a function or vector name for execution when this item is selected.
  527. This  execution  is performed in conjunction with the event-handler (please
  528. see Using the event handler for details.)
  529.  
  530. Also  contained  in  this  window is a menu which allows you to specify the
  531. items  which  the  current  item  should mutually-exclude.  (Mutual-exclude
  532. refers  to  one  item  which,  when selected, will un-check a list of other
  533. items  on  the  same  menu, or other subitems of the same menuitem.) Notice
  534. that  the item upon which you are working is also listed here because it is
  535. perfectly  legal to make an item exclude itself, though it rarely makes any
  536. sense.   As  you  move,  insert  or  delete  items  from  the  menu,  these
  537. mutual-exclude values are automatically maintained by PW2.5.
  538.  
  539. Work  on  images  for...  allows you to load or delete IFF brush imagery to
  540. use  for menuitem rendering.  You can load both the render (unselected) and
  541. select  (selected) imagery.  PW automatically makes the select boxes of the
  542. items in the list wide enough for the images to be attractively integrated,
  543. even if you mix images and text on a single item list.
  544.  
  545. Work  on  subitems  for...   sets  up  yet  another new menu, just slightly
  546. different from the last one:
  547.  
  548.      Append a subitem
  549.      Subitem columns(1)
  550.      Insert a subitem before...
  551.      Move a subitem
  552.      Edit a subitem
  553.      Work on images for...
  554.  
  555.      Delete a subitem
  556.  
  557. The slight difference is Subitem columns.  With this option you can display
  558. your subitems in up to 9 columns.
  559.  
  560. Other  on  the Subitem menu offers a return to the Main menu or a return to
  561. the Menuitem menu, while Other on the Menuitem menu only lets you return to
  562. the Main menu.
  563.  
  564.  
  565. GADGETS:
  566.  
  567. All  gadgets  created  by  PowerWindows  are  rectangular,  but they can be
  568. virtually  any size from a few pixels to the entire area of the window, and
  569. with  the  Clone  a  gadget  feature you can make very professional-looking
  570. screens  filled  with  gadgetry  of  varying sorts and colors.  PW lets you
  571. create  all  three Intuition gadget types, BOOLEAN, STRING and PROPORTIONAL
  572. and work with them in a what you see is what you get fashion.  You can also
  573. load  custom  imagery  for  the  the  render  (unselected)  and  the select
  574. (selected)  fields  of  a  gadget.   Additionally,  most of the flags which
  575. control the gadget's appearance are also WYSIWYG.
  576.  
  577. With  PowerWindows version 2.5, you can also work with two special types of
  578. BOOLEAN  gadgets:   PopUpGadgets and DragGadgets.  Both of these new gadget
  579. types  are  meant  to  be  used with the InovaTools1 package available from
  580. INOVATRONICS,  Inc.   If  you  do  not  intend to use InovaTools1 with your
  581. software,  then  do  not use these new gadgets types in your design.  PW2.5
  582. has  the  support routines for the InovaTools1 functions built-in to it, so
  583. you can design these special items, even if you cannot use them in your own
  584. programs.
  585.  
  586. PopUpGadgets are BOOLEAN gadgets that, when pressed, will display a menu of
  587. your  design  under  the  mouse  and allow the user to select a menuitem or
  588. subitem  just  as  if a normal intuition menu were being used.  You specify
  589. that  you  want a gadget to be a PopUpGadget through the Define gadget type
  590. command.   Then  you  may  edit the menu attached to the gadget through the
  591. Work  on  PopUpGadget  menuitems command.  After making a PopUpGadget, when
  592. you  click  on  the  gadget  your  special menu will be displayed under the
  593. mouse.
  594.  
  595. DragGadgets  are  BOOLEAN  gadgets which use an image for render and may be
  596. dragged around the screen.  You can make the gadget stay where it is put or
  597. rubber-band  back, move around just in the window in which they are defined
  598. or allow them to move anywhere on the screen!  You can also control the way
  599. in  which  the render image is displayed while the gadget is being dragged,
  600. and the dimensions of the area in which the gadget can move.  Once you have
  601. created  a  DragGadget,  you  can  click on it and drag it anywhere in your
  602. window.
  603.  
  604. Both  of  these gadget types are fully WYSIWYG within PowerWindows.  A full
  605. discussion of their properties and how to control them are beyond the scope
  606. of  this  documentation.   You  must  refer  to  the InovaTools1 manual for
  607. further information.
  608.  
  609. Under the Gadgets menu you'll find:
  610.  
  611.      Add a gadget
  612.      Move a gadget
  613.      Clone a gadget
  614.      Re-size a gadget
  615.      Define gadget type
  616.      Work on gadget borders
  617.      Work on gadget text
  618.      Work on gadget images
  619.      Work on PopUpGadget menuitems
  620.  
  621.      Move gadget to start of list
  622.      Choose gadget successor
  623.      Move gadget to end of list
  624.  
  625.      Delete a gadget
  626.  
  627. Add  a gadget waits for you to click in one of your windows to position the
  628. TopLeft  corner of your gadget's border.  Drag the mouse to size the gadget
  629. appropriately.   Click  the  mouse  button again and the box becomes a real
  630. BOOLEAN  gadget,  hooked  into your window.  Note that your ability to size
  631. the  gadget, and then later to move it, may be impeded by the status of the
  632. Gadget  collision  checking flag which, when on, will prevent the bisection
  633. of  one  gadget  by  another.   You  may  wish to disable this function for
  634. special applications, but be aware that the designers of Intuition strongly
  635. discourage the practice of overlapping or intersecting gadgets.
  636.  
  637. Move  a  gadget lets you change the position of a gadget by clicking inside
  638. the  gadget  and dragging it to a new location.  Any associated gadget text
  639. will  be moved also.  That is, its position relative to the gadget will not
  640. change.   When  moving  STRING  gadgets,  after selecting the gadget, press
  641. return.   After  that,  the  gadget  may be moved normally.  Press the left
  642. mouse  button  when  it  is  properly  positioned.   Similarly, always move
  643. PROPORTIONAL  gadgets  by  their knobs, not by clicking inside the gadget's
  644. container.
  645.  
  646. You may move a gadget from one of your windows to another by simply picking
  647. the  gadget  to  move  and moving your mouse until it is over the window to
  648. which  you  wish  to  move  the gadget.  Then click the mouse again and the
  649. gadget will be removed from the old window and deposited in the new window.
  650.  
  651. Clone a gadget lets you duplicate a gadget exactly, both in terms of hitbox
  652. size  and  in  terms of gadget flags, text, and imagery or borders.  Select
  653. the  gadget  to clone and a new gadget, slightly offset to the BottomRight,
  654. will be created.  Now drag the pointer to position the duplicate gadget and
  655. click the left mouse button when you are finished.
  656.  
  657. You can clone gadgets from one window to another in exactly the same manner
  658. as they are moved from one window to another, as described above.
  659.  
  660. Re-size  a  gadget  gives  you  another opportunity to get that gadget just
  661. right.  Click and hold the select button when the pointer is on the desired
  662. gadget.   Dragging  the  mouse  around  will re-size the gadget.  Click the
  663. button again when the gadget is the correct size.
  664.  
  665. Define  gadget  type,  after selecting a gadget to work on, gives you a new
  666. window  full of various flag settings and decisions you can make concerning
  667. your  gadget.  From this screen, you can determine the gadget type, set its
  668. size  and  origin locations, and specify various data for the generation of
  669. your gadget's source code.
  670.  
  671. A few Define gadget type notes:
  672.  
  673. The  relativity  flags GRELRIGHT, GRELBOTTOM, GRELWIDTH, and GRELHEIGHT, if
  674. selected,  ARE  put  into  effect  while  in  PowerWindows.  Therefore, any
  675. changes  made  to  the  size  of  the  window in which the relative gadgets
  676. reside,  will  effect the position and/or size of the relative gadgets.  Be
  677. careful:  it is possible, for instance, to make a gadget with the GRELWIDTH
  678. flag  set, then resize its containing window to be so small that the gadget
  679. attains  negative  dimensions.   Intuition  will not object, but it will be
  680. impossible  for your user or yourself to select this gadget.  Use the Clean
  681. up  command  from the Windows menu to fix any problems arising from the use
  682. of this WYSIWYG feature.
  683.  
  684. BORDER-ONLY  and  IMAGE-ONLY  gadgets  are gadgets only in the context of a
  685. PowerWindows  editing  session.  At the time of source code generation, all
  686. of  the borders of the BORDER-ONLY gadgets will be written as a linked list
  687. of Border structures, one for each BORDER-ONLY gadget, and likewise for the
  688. IMAGE-ONLY  gadgets.   Any  text  associated  with  these  gadgets  is  NOT
  689. GENERATED  AT  ALL.  Use BORDER-ONLY gadgets to draw boxes around groups of
  690. gadgets  and  text,  as  we  have done with this screen, and use IMAGE-ONLY
  691. gadgets to place various images around your display.
  692.  
  693. PopUpGadgets are BOOLEAN gadgets that have a PopUpMenu attached to them for
  694. use with InovaTools1.
  695.  
  696. DragGadgets  are BOOLEAN gadgets that can be dragged around the display and
  697. use  imagery  for  render.  Selecting this option will bring up a requester
  698. allowing  you  to indicate the dimensions of the DragGadget's bounding-box,
  699. as  well  as  the various flags used by DragGadgets.  Also, if the language
  700. you are working with supports vectored execution, you can specify a routine
  701. to  be  executed each time the DragGadget is moved by the user.  The string
  702. describing this routine is generated in your source code.
  703.  
  704. In  the BOOLMASK gadget, you can specify a pointer to a BOOLMASK for use in
  705. a BoolInfo structure.  PW will not generate a BoolInfo structure unless you
  706. put a string into this field.
  707.  
  708. In  the  EXCLUDE,  GADGETID  and  USERDATA  gadgets, you can enter any text
  709. strings  that  you want used for these same fields in the Gadget structure.
  710. Because  these  fields are not used by Intuition, you can use them for your
  711. own  data.  You must provide any data necessary to resolve these references
  712. at compile or run time.
  713.  
  714. The  FUNCTION  gadget  lets you specify a function or vector which is to be
  715. executed  when  this  gadget  is selected.  See Using the event-handler for
  716. more details.
  717.  
  718. In  the SOURCE LABEL gadget, you can enter the exact text for the structure
  719. name  to  use  when  generating  source for this gadget.  Does not apply to
  720. BORDER-ONLY or IMAGE-ONLY gadgets.
  721.  
  722. The  number  in  the string gadget LENGTH field must include one extra byte
  723. for the end-of-line null byte required by Intuition.
  724.  
  725. If  you turn on the UNDOBUFFER gadget, PW will generate one undo buffer for
  726. all  those  gadgets  that  refer to it.  The buffer will be as large as the
  727. largest string gadget buffer.
  728.  
  729. The HBODY and VBODY values are a convenient way to indicate the size of the
  730. AUTOKNOB  of  proportional gadgets and the distance which the knob can move
  731. each  time the gadget's container is hit.  A value of 10, for example, will
  732. make  the  AUTOKNOB  1/10 the size of the entire container and it will move
  733. 1/10 of the container each time the container is hit.
  734.  
  735. Please  see  the  Amiga ROM Kernal manuals for complete descriptions of all
  736. the Gadget flags listed on this screen.
  737.  
  738. Work  on  gadget borders concerns your control of a gadget's border.  After
  739. you  choose the gadget to work with, you have a new menu with the following
  740. topics:
  741.  
  742.      Borders
  743.      Other
  744.  
  745. On  the  Borders  menu,  you  will  find three functions for the drawing of
  746. custom  borders  (1.   freehand  - where you click in your window, drag and
  747. click  to  set the end-point of that vector, and double-click when down; 2.
  748. rectangle  -  where you click for the TopLeft corner of the rectangle, drag
  749. and  click when done; and 3.  square - in which you click to set the center
  750. of  the square and drag to define its size), a command to edit the offsets,
  751. drawmode  and  pen  number  of  the  border  (for custom border or standard
  752. border),  and  a  command to delete any custom border.  The Other menu lets
  753. you  turn  off the standard border, pick a new gadget to work on, or return
  754. to the main menu.
  755.  
  756. If  you  turn  off  the  standard border (not the same as border-only), the
  757. gadget  border  will  still  be  displayed  by PowerWindows for purposes of
  758. editing  and  identification.  Any source code generated, however, will not
  759. have  a  gadget  border  structure  referenced  or  generated.  In order to
  760. generate a gadget with absolutely no render, you MUST turn off the standard
  761. border.
  762.  
  763. Work  on  gadget text gives you a new menu that is identical in function to
  764. the  functions  concerning  windowtext in the Windows menu.  Note, however,
  765. that  windowtext  is  relative  to  a  window  and  gadgettext to a gadget.
  766. Otherwise  the principles are the same.  Write the text, position it in the
  767. window  by  clicking and dragging the mouse, and click again when all is as
  768. it should be.
  769.  
  770. Work  on  gadget  images  lets you pick a gadget for which to load imagery,
  771. then  gives  you  a new menustrip relating to imagery for that gadget.  You
  772. can  load  an  IFF  brush for the gadget render of the gadget select image,
  773. edit  the offsets for the image, make the gadget hitbox the exact same size
  774. as the image, or delete image.  PW will automatically set the correct flags
  775. in  the  gadget  structure  allowing you to use the image, delete it, etc.,
  776. without worrying about the render or highlighting flags.
  777.  
  778. Work  on  PopUpGadget  menuitems  allows you to edit the menu attached to a
  779. PopUpGadget  just as if it were a normal PowerWindows menu.  After choosing
  780. this  option,  simply click on the PopUpGadget with which you wish to work,
  781. and  PW2.5 will give you a new menustrip for editing the menuitems attached
  782. to your PopUpGadget.  You can do anything to a PopUpGadget's menuitems that
  783. you  can  do  to  a  normal  menu's  items,  including  the use of imagery,
  784. subitems,  various highlighting methods and mutual-exclusion of other items
  785. on  the  same  PopUpMenu.   You  cannot, however, use alternate command key
  786. sequences  for PopUpGadgets because Intuition would confuse these keys with
  787. those reserved for common Amiga menus.
  788.  
  789. Move gadget to start of list lets you pick a gadget to move to the start of
  790. the  gadget  list.  This command and Move gadget to end of list can be used
  791. to  crate  lists of gadgets in an exact order.  This lets you use only part
  792. of a gadget list in a given situation.
  793.  
  794. Specify  gadget  successor lets you indicate that "this" gadget comes right
  795. after  "that"  gadget  in the list.  In the event that two gadgets overlap,
  796. this command lets you control which gadget is in "front".
  797.  
  798. Delete  a  gadget  deletes  whatever gadget you choose.  To delete a string
  799. gadget,  you  must select and press RETURN.  Be careful!  There is no going
  800. back.
  801.  
  802.  
  803. KNOBS:
  804.  
  805. Knobs  are  special, new input devices supported by InovaTools1.  They have
  806. the appearance of circular, analog-type dials.  They can be rendered in any
  807. of  the  standard  resolutions and are highly configurable.  To use a knob,
  808. simply  click in the body of the knob.  If the arrow of the knob (the dial,
  809. in  other  words)  is  not  already  at  the position on the knob where you
  810. clicked,  it  will  move there.  Then, as you move the mouse the knob arrow
  811. will  move around the knob to a new setting.  To stop moving the dial, just
  812. release the mouse select button.
  813.  
  814. A  complete  discussion  of knob properties can be found in the InovaTools1
  815. documentation,  and  you  must  have  that  software in order to make knobs
  816. function in your software.
  817.  
  818. If  you  look  at  the  Knobs  menu,  you  will  see  the following options
  819. available:
  820.  
  821.      Add a knob
  822.      Move a knob
  823.      Clone a knob
  824.      Re-size a knob
  825.      Edit knob parameters
  826.  
  827.      Delete a knob
  828.  
  829. Add  a knob works very much like Add a gadget.  After choosing this option,
  830. click  at  the point inside your window at which you want the center of the
  831. knob  to  appear.   Then you simply drag your mouse to size the knob.  When
  832. the outline of the knob's diameter looks correct to you, click on the mouse
  833. again  inside the window and a real Knob will be added to your window.  You
  834. can  change  its  size,  position  and  many  other  options with the other
  835. commands from this menu.
  836.  
  837. Move a knob works in this way:  click on the knob you want to move, drag it
  838. (even  to  a  new  window  if you like) and click again when it is properly
  839. placed.   If  you  move  a knob to another window, the knob will be removed
  840. from the window of origin, and appended to the KnobList of the destination.
  841.  
  842. Clone  a  knob is the functional counterpart of Clone a gadget.  Just click
  843. on  the  knob to clone and an exact duplicate knob will be created that you
  844. can  then move to someplace in that same window or to another window if you
  845. so choose.
  846.  
  847. Re-size  a  knob  allows you to click on the knob to resize, drag the mouse
  848. and  then  click  again  when  the knob has reached the desired dimensions.
  849. Because  certain  rasters  and  memory must be allocated in order to fill a
  850. knob  with a particular color, making a knob too large can result in a knob
  851. that cannot be filled.
  852.  
  853. Edit  knob parameters will wait for you to select the knob you want to edit
  854. with  the  mouse, then will open a requester with gadgets inside it for all
  855. of  the  various  flags  and  settings  that  can  be determined for knobs.
  856. Although you must refer to the InovaTools1 manual for a thorough discussion
  857. of all these parameters, below is a short list of the items you can control
  858. with this command:
  859.  
  860.      X and Y coordinates of the knob's center;
  861.      knob flags, including DRAW, FILL, COMPLEMENT, RANGED,
  862.           CALCVALUE, MARKED, and MARKENDS;
  863.      the current settings for the knob's position, range of
  864.           movement, and the number of unique steps in its range;
  865.      the radius of the knob and the length of the knob's arrow
  866.           (dial);
  867.      the colors used for rendering the knob;
  868.      the label to be used in the generated source code for this
  869.           knob;
  870.      fields to name the text strings for the UpdateRoutine,
  871.           KnobID, and UserData fields of the Knob structure.
  872.  
  873. When  you  have  properly  set all of the knob's parameters click on the OK
  874. gadget  and  the  knob  you  changed  will  be redisplayed, reflecting your
  875. changes.   Note  that  if you happen to accidentally move a knob beyond the
  876. edge  of  your  window, you may use the Clean up command to bring all knobs
  877. and gadgets back into the boundaries of a selected window.
  878.  
  879. Delete  a  knob  waits  for you to click on the knob you want to delete and
  880. then  removes  it  from  the  KnobList  of  its window.  The window is then
  881. redrawn without the knob.
  882.  
  883.  
  884. PREFERENCES:
  885.  
  886. This  menu  gives  you  some flexibility in using PowerWindows 2.5.  In it,
  887. you'll see:
  888.  
  889.      OK prompts
  890.      PW backdrop
  891.      Auto Redraw
  892.      Auto Select
  893.      Mouse coordinates
  894.      Gadget collision checking
  895.      Image color remapping
  896.      Image compression
  897.      Trim extra bitplanes
  898.      Source code comments
  899.      Source code spacing (TAB)
  900.  
  901. The  default  condition  for all of these settings is ON, except for the PW
  902. backdrop  option.  However, these settings, along with other relevant data,
  903. are  stored  in  each  PW intermediate file that you save, and are restored
  904. when the PW intermediate file is reloaded.
  905.  
  906. OK  prompts,  when checked, gives you a prompting requester at the start of
  907. many  gadget  and  text related functions.  At these prompts, you also have
  908. the  ability  of  cancelling your action.  You can disable these prompts by
  909. un-checking  OK  prompts  in this menu.  You can get the prompt back at any
  910. time  in the middle of a function by pressing the "HELP" key.  You will get
  911. the original help prompt back with the same chance to cancel the operation.
  912.  
  913. PW  backdrop  controls  the PW command window.  If this is checked, then it
  914. becomes  a  backdrop  window.   This means that no window opened can appear
  915. behind  the  PW command window.  Normally, this provides a working area for
  916. your  custom  window  design.   However, if you wish to make the PW command
  917. window smaller, or design your own backdrop window, then use this option to
  918. make PW use a standard window.
  919.  
  920. Auto  redraw  lets  you  stop PowerWindows from redrawing your window after
  921. every change you make.
  922.  
  923. Auto  select, when checked, tells PowerWindows that each time you click the
  924. left  mouse button, or select a gadget, in one of your windows, that the PW
  925. command  window  should  be  activated.   This way, the PW menus are always
  926. available.  However, if you are doing a significant amount of menu editing,
  927. and  are not using a drag bar in your window for safe selects, then you may
  928. wish to turn this function off so that you can easily select your window in
  929. order to inspect your menus.
  930.  
  931. Mouse  coordinates, when set, shows the absolute X and Y coordinates of the
  932. mouse  on  the  right  side  of  the  PW command window's title bar, during
  933. certain gadget and text related functions.
  934.  
  935. Gadget  collision  checking,  when checked, makes sure that your gadget hit
  936. boxes  do  not bisect one another.  If you disable this, gadgets can appear
  937. on  top  of  each  other, which can cause some problems for the user.  Note
  938. that the creators of Intuition strongly discourage this practice.
  939.  
  940. Image  color  remapping instructs PW to modify the colors of each IFF brush
  941. image  that  you  load.  The purpose of the modification is to best realize
  942. the  original intent of the colors used in the IFF image, when working with
  943. a palette which is different from that of the image.
  944.  
  945. Image  compression makes PowerWindows detect and remove any bitplanes in an
  946. image  which  are  all  0  or  all  1.   The image variables, PlanePick and
  947. PlaneOnOff  are  adjusted  accordingly.   This saves memory and reduces the
  948. amount of ImageData PW generates.  Note, however, that if PW performs Image
  949. color  remapping  on  an  image,  then  planes  that  were  candidates  for
  950. compression may be used to represent the remapped colors.
  951.  
  952. Trim  extra  bitplanes  forces  each  image  loaded  to  consist of no more
  953. bitplanes  than in the screen onto which it is loaded.  If the image is not
  954. to  be moved at runtime, from one resolution to another, this option simply
  955. throws away undisplayed data.
  956.  
  957. Source code comments, when checked, lets you tell PowerWindows to include a
  958. comment  for  almost  every  line of generated source code, explaining what
  959. element  of  each  structure  that  source  line represents.  Excluding the
  960. comments results in a smaller, less understandable source file.
  961.  
  962. Source  code  spacing  allows  you to set the number of spaces PowerWindows
  963. will  indent each source line with.  Alternatively, you can choose TAB as a
  964. separator, which is the default.
  965.  
  966.  
  967. OTHER TOPICS:
  968.  
  969. Repeating commands:  The F10 key will repeat the last menu command that you
  970. gave  to PW.  In several instances, however, PW will not allow a command to
  971. be  repeated  because  it  is  no longer valid or because your verification
  972. should be required, as in the deletion of text or menus, etc.
  973.  
  974. Cancelling commands:  When using the gadget and text commands which require
  975. you  to  click  in your window, you can press the "HELP" key at any time to
  976. redisplay  the  OK  prompt  that explains the current procedure.  From that
  977. prompt, you can press CANCEL to abort the current command.
  978.  
  979. Using  the event-handler:  The event-handler that PowerWindows can generate
  980. uses  the  data  that  you  would  normally receive in an IntuiMessage from
  981. Intuition.   You  can specify function addresses for gadgets, nemuitems and
  982. subitems.   There  is a string gadget labeled FUNCTION found on the editing
  983. requesters for each of these objects which you must fill in with the proper
  984. text  for  your  target  language.   PowerWindows  will  generate  a single
  985. event-handler  for all of these structures.  You process your IntuiMessages
  986. in the following ways:
  987.  
  988.      Gadgets:
  989.           wait for an IntuiMessage of GADGETUP or GADGETDOWN
  990.           get the object address from the IntuiMessage (this is
  991.                     the gadget_address)
  992.           Reply the message to free Intuition for other tasks
  993.           invoke the event-handler with
  994.                     HandleEvent(gadget_address)
  995.      MenuItems and Subitems:
  996.           wait for an IntuiMessage of MENUPICK
  997.           get the code field from the IntuiMessage (this is the
  998.                     MENUNUM)
  999.           Reply the message to free Intuition for other tasks
  1000.           get the item_address from Intuition with
  1001.                     itemAddress(MENUNUM);
  1002.           invoke the event-handler with
  1003.                     HandleEvent(item_address);
  1004.  
  1005. The  event-handler  will, if the gadget or menuitem is matched, execute the
  1006. indicated function, passing the same object address through to the function
  1007. as  a  parameter.   Please  see  the example file for the language your are
  1008. working in for specific details.
  1009.  
  1010. Troubleshooting:
  1011.  
  1012. "I  can't  get  PW to show its menu!":  Try clicking in one of your windows
  1013. and pressing F1.  This will bring PW to the front and activate its window.
  1014.  
  1015. "I  can't  get my custom menu to display!":  Turn Auto Select off and click
  1016. in your window.  Press F1 when finished to return to the PW main menu.  Or,
  1017. select  the drag bar, foreground or close gadget of the window and then you
  1018. can  look at your menu.  Click inside it again to go back to the PW command
  1019. menu or press F1.
  1020.  
  1021. "How  do  I  make a custom knob for a PROPGADGET?":  Declare a proportional
  1022. gadget  and  load  in the IFF brush for the knob.  You can load brushes for
  1023. both the unselected and selected knob render.  Ta-da!
  1024.  
  1025. "When  I  load  in  an  image,  PowerWindows  seems  to HANG!":  PW is just
  1026. remapping  the  image.   Sometimes,  it  can  take  a  while.  A 320 x 200,
  1027. 5-bitplane  image  can  take  up to 16 seconds to remap.  Don't panic, just
  1028. wait.   Or,  if  you  don't  need color remapping, turn off the Image color
  1029. remapping flag under the Preferences menu.
  1030.  
  1031. "I'm lost and I don't know what to do!":  You are probably in the middle of
  1032. a gadget command.  Press HELP.  It will tell you what you are doing and let
  1033. you cancel or continue doing it.  If that doesn't work, click inside one of
  1034. your  edit  windows  or  the  PW  command window and press F1.  This should
  1035. return you to the PW command level.
  1036.  
  1037. End.
  1038.